﻿using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace WareHouse.Domain.Finances
{
    /// <summary>
    /// 应收表
    /// </summary>
    [SugarTable("Receivable")]
    public class Receivable
    {
        /// <summary>
        /// 应收ID
        /// </summary>
        [SugarColumn(IsPrimaryKey = true)]
        public int ReceivableId { get; set; }

        /// <summary>
        /// 应收流水号
        /// </summary>
        public string ReceivableCode { get; set; }
        /// <summary>
        /// 名称
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 财务类别ID 外键
        /// </summary>
        public int FinanceTypeId { get; set; }

        /// <summary>
        /// 付款方
        /// </summary>
        public string Payer { get; set; }

        /// <summary>
        /// 收款方
        /// </summary>
        public string Payee { get; set; }

        /// <summary>
        /// 应收金额
        /// </summary>
        public decimal ReceivableMoney { get; set; }

        /// <summary>
        /// 实收金额
        /// </summary>
        public decimal FundsReceived { get; set; }

        /// <summary>
        /// 付款机构
        /// </summary>
        public string PaymentInstitutes { get; set; }

        /// <summary>
        /// 最后付款日期
        /// </summary>
        public DateTime LastPaymentDate { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 审核状态
        /// </summary>
        public AuditStatus AuditStatus { get; set; } = AuditStatus.待审核;

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreateTime { get; set; }= DateTime.Now;
    }

}
